package com.sangeng.controller;

import com.sangeng.domain.ResponseResult;
import com.sangeng.service.LinkService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 友链管理
 */
@RestController
@RequestMapping("/link")
public class LinkController {

    @Autowired
    private LinkService linkService;

    // 查询所有状态为审核通过的友链 status = "0"
    @GetMapping("/getAllLink")
    public ResponseResult getAllLink(){

        ResponseResult result = linkService.getAllLink();

        return result;
    }
}
